import sg.edu.nus.comp.cs3243.pipedream.*;

import java.util.Random;
import java.io.*;
import java.util.*;

/*	Just a class for us to test the average score 
 * Usage : run tester with the number of loops as the argument
 * Default : 10 cycles
 */

public class Tester
{
	Tester() { ; }

	public static void main(String[] args)
	{
		int loops;
		if (args.length < 1) loops = 10;
		else loops = new Integer(args[0]).intValue();
		String[] stub = new String[] { "123" };
		int score=0;
		int min = 999;
		int max = -1;
		for (int i = 0; i < loops; i++)
		{
			MyPlayer mp = new MyPlayer();
			mp.main(stub);
			score += mp.FinalScore;
			if (mp.FinalScore < min) min = mp.FinalScore;
			if (mp.FinalScore > max) max = mp.FinalScore;
		}
		double temp = score;
		temp = temp / loops;
		System.out.println();
		System.out.println("Average Score for " + loops + " rounds = " + temp);
		System.out.println("Minimum Score for " + loops + " rounds = " + min);
		System.out.println("MAximum Score for " + loops + " rounds = " + max);
	}
}